package com.tenton;

import javax.swing.*;
import java.net.URL;

/**
 * @Author:Tenton
 * @Date: 2020/10/31 15:46
 * @Description: 存放外部数据
 */
public class Data {
    //顶部的图片 URL :定位图片的地址
    public static URL headerURL = Data.class.getResource("/statics/header.png");
    //使路径下的资源变成一张图片
    public static ImageIcon header = new ImageIcon(headerURL);
    //头部
    public static URL upURL = Data.class.getResource("/statics/up.png");
    public static URL downURL = Data.class.getResource("/statics/down.png");
    public static URL leftURL = Data.class.getResource("/statics/left.png");
    public static URL rightURL = Data.class.getResource("/statics/right.png");
    public static ImageIcon up = new ImageIcon(upURL);
    public static ImageIcon down = new ImageIcon(downURL);
    public static ImageIcon left = new ImageIcon(leftURL);
    public static ImageIcon right = new ImageIcon(rightURL);
    //身体
    public static URL bodyURL = Data.class.getResource("/statics/body.png");
    public static ImageIcon body = new ImageIcon(bodyURL);
    //食物
    public static URL food1URL = Data.class.getResource("/statics/food1.png");
    public static URL food2URL = Data.class.getResource("/statics/food2.png");
    public static URL food3URL = Data.class.getResource("/statics/food3.png");
    public static ImageIcon food1 = new ImageIcon(food1URL);
    public static ImageIcon food2 = new ImageIcon(food2URL);
    public static ImageIcon food3 = new ImageIcon(food3URL);
}